home *** CD-ROM | disk | FTP | other *** search
- /*
- Make QTVR Panorama 1.0b1
-
- A simple PowerPlant application for processing PICT files into QuickTime VR™ movies.
-
- Created 29 Jan 1996 by EGH
-
- Copyright © 1996, Apple Computer, Inc. All rights reserved.
- */
-
- #pragma once
-
- #ifndef __MOVIES__
- #include <Movies.h>
- #endif
-
- #include <LDocApplication.h>
- #include <LListener.h>
-
- #include "CPreferences.h"
-
- #if PRAGMA_ALIGN_SUPPORTED
- #pragma options align=mac68k
- #endif
-
- typedef struct P2VRPrefsRec
- {
- // default movie making parameters
- Int16 width;
- Int16 height;
- Fixed pan;
- Fixed tilt;
- Fixed zoom;
- CodecType codec;
- CodecQ spatialQuality;
- Int16 depth;
-
- Str31 tileSuffix;
- Str31 movieSuffix;
-
- Boolean replaceFiles;
-
- // drop mode or what
- Boolean dropMode;
- } P2VRPrefsRec, *P2VRPrefsPtr, **P2VRPrefsHdl;
-
- #if PRAGMA_ALIGN_SUPPORTED
- #pragma options align=reset
- #endif
-
- class CApp :
- public LDocApplication,
- public LListener
- {
- public:
-
- CApp();
- virtual ~CApp();
-
- virtual Boolean ObeyCommand(
- CommandT inCommand,
- void *ioParam = nil);
- virtual void FindCommandStatus(
- CommandT inCommand,
- Boolean &outEnabled,
- Boolean &outUsesMark,
- Char16 &outMark,
- Str255 outName);
-
- virtual void DoAEOpenOrPrintDoc(
- const AppleEvent &inAppleEvent,
- AppleEvent &outAEReply,
- Int32 inAENumber);
- virtual void ChooseDocument();
- virtual void OpenDocument(
- FSSpec *inMacFSSpec);
-
- virtual void StartUp();
-
- void ProgressEvents();
-
- virtual void ListenToMessage(
- MessageT inMessage,
- void *ioParam);
-
- P2VRPrefsHdl GetPreferences()
- { return mPrefsHdl; }
-
- void BugUserTilSwitchedIn();
-
- private:
-
- static Boolean sCancelled;
- static Boolean sBusy;
- static LWindow *sProgressWindow;
- static Boolean MovieProgressProc(
- StringPtr inMessage);
-
- Boolean mDropMode;
-
- P2VRPrefsHdl mPrefsHdl;
- };
-
- const ResIDT ALRT_NoQT = 130;
- const ResIDT ALRT_WeDontPrint = 131;
- const ResIDT ALRT_ConfirmSize = 132;
- const ResIDT ALRT_ConfirmOrientation = 133;
-
- const OSType Creator_ = 'p2vr';
-
- const OSType ResType_Preferences = 'prEF';
-
- extern CApp *gApp;
-
- const CommandT cmd_DropMode = 100;
- const CommandT cmd_Preferences = 101;
-
- const ExceptionCode Exception_UserCancelled = 99;
- const ExceptionCode Exception_BadParameter = 100;
-
- typedef Boolean (*ProgressProc)(
- Str255 inProgressMessage);
-
- const ResIDT WIND_Pict2VR = 456;
- const ResIDT WIND_Preferences = 457;
- const ResIDT WIND_Splash = 458;
-
- enum
- {
- str_Making = 1,
- STRx_Progress = 223
- };
-
- // ==============================================
- // stuff for telling the app to make a QTVR movie
-
- typedef struct MovieMakinRec
- {
- FSSpec srcSpec;
- FSSpec tileSpec;
- FSSpec destSpec;
- Int16 width;
- Int16 height;
- Fixed pan;
- Fixed tilt;
- Fixed zoom;
- CodecType codec;
- CodecQ spatialQuality;
- Int16 depth;
- Boolean completed; // response
- } MovieMakinRec, *MovieMakinPtr;
-
- const MessageT msg_MakeMovie = 'mkmv';
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-